'use strict';
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
const l = require('../../nodes/Scalar.cjs'),
  r = {
    identify: t => typeof t == 'boolean',
    default: !0,
    tag: 'tag:yaml.org,2002:bool',
    test: /^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,
    resolve: t => new l.Scalar(t[0] === 't' || t[0] === 'T'),
    stringify({ source: t, value: e }, o) {
      if (t && r.test.test(t)) {
        const a = t[0] === 't' || t[0] === 'T';
        if (e === a) return t;
      }
      return e ? o.options.trueStr : o.options.falseStr;
    },
  };
exports.boolTag = r;
